<extend name="Public:innerbase" />
<block name="content">
<div class="container-fluid">
	<div class="page-header">
		<h4 class="page-title">微信红包</h4>
	</div>
	<a href="{:U('Redpacket/set')}" title="添加活动" class="btn btn-success">添加活动</a>
	<hr/>
	<table class="table table-bordered table-strip">
		<thead>
			<tr>                                 
				<th width="100">活动名称</th>
				<th width="50">红包类型</th>
				<th width="100">红包属性</th>
				<th width="75">领取状态</th>
				<th width="135">活动时间</th>
				<th width="110">操作</th>
			</tr>
		</thead>
		<tbody>
		<volist name="items" id="list">
		<tr>
			<td>{$list.title}</td>
			<td>
				<if condition="$list.packet_type eq '1'">
				手气红包
				<else />
				普通红包
				</if>
			</td>
			<td>
				发放个数：{$list.item_num}<br/>
				<if condition="$list.packet_type eq '2'">
				　总金额：{$list.item_sum}<br />
				面额上限：{$list.item_max}
				<else />
				单个面额：{$list.item_unit}
				</if>
			</td>
			<td>
				已领：{$list.totalPerson|default=0}人
				总额：{$list.totalMoney|default=0}元
			</td>
			<td>{$list.start_time|date="Y-m-d",###} 至  {$list.end_time|date="Y-m-d",###}</td>
			<td class="norightborder" align="center">
				<a href="{:U('Redpacket/prize_log',array('token'=>$token,'id'=>$list['id']))}">领取记录</a>
				|
				<a href="{:U('Redpacket/set',array('token'=>$this->token,'id'=>$list['id']))}">修改</a>
				|
				<a href="javascript:spark.confirm_jump('您确定要删除吗?', '{:U('Redpacket/del',array('id'=>$list['id']))}');">删除</a>
			</td>
		</tr>
		</volist>
		</tbody>
	</table>
</div>
</block>